package com.ck.ck_back.service;

import com.ck.ck_back.pojo.LikeComment;
import com.ck.ck_back.pojo.LikeProduction;

import java.util.List;

public interface likecommentservice {
    /**
     * 点赞。状态为1
     * @param likedCommentId
     * @param likedPostId
     */
    void saveLiked2Redis(int likedCommentId, String likedPostId);

    /**
     * 取消点赞。将状态改变为0
     * @param likedCommentId
     * @param likedPostId
     */
    void unlikeFromRedis(int likedCommentId, String likedPostId);


    /**
     * 获取Redis中存储的所有点赞数据
     * @return
     */
    List<LikeComment> getLikedDataFromRedis();

    void deal_withdata(List<LikeComment> likeComments);

//    给前端返回是否点赞的信息
    int getstate(int likedCommentId, String likedPostId);
}
